<template name="addCollectionOptions">
    {{#if isAddCollectionOptionSelected "CAPPED"}}
        {{> capped}}
    {{/if}}
    {{#if isAddCollectionOptionSelected "FLAGS"}}
        {{> flags}}
    {{/if}}
    {{#if isAddCollectionOptionSelected "INDEX_OPTION_DEFAULTS"}}
        {{> indexOptionDefaults}}
    {{/if}}
</template>


<template name="capped">
    <div class="form-group">
        <label class="col-lg-2 control-label">{{_ "capped"}}
        </label>
        <div class="col-lg-5">
            <input id="inputCappedCollectionSize" required="true" type="number"
                   min="0"
                   placeholder="{{_ "size"}} {{_ "in_bytes"}}"
                   class="form-control">
        </div>
        <div class="col-lg-5">
            <input id="inputCappedCollectionMaxDocs" required="true" type="number" min="0"
                   placeholder="{{_ "max_documents"}}"
                   class="form-control">
        </div>
    </div>
</template>

<template name="flags">
    <div class="form-group">
        <label class="col-lg-2 control-label">{{_ "use_2_sizes_indexes"}}
        </label>
        <div id="divTwoSizesIndexes" class="col-lg-10">
            <input id="inputTwoSizesIndexes" type="checkbox"
                   class="form-control"
                   checked=""
                   style="position: absolute; opacity: 0;"/>
        </div>
    </div>
    <div class="form-group">
        <label class="col-lg-2 control-label">{{_ "no_padding"}}
        </label>
        <div id="divNoPadding" class="col-lg-10">
            <input id="inputNoPadding" type="checkbox"
                   class="form-control"
                   checked=""
                   style="position: absolute; opacity: 0;"/>
        </div>
    </div>
</template>

<template name="indexOptionDefaults">
    <div class="form-group">
        <label class="col-lg-2 control-label">{{_ "index_option_defaults"}}
        </label>
        <div id="divIndexOptionDefaults" class="col-lg-10">
                                                <textarea id="txtIndexOptionDefaults"
                                                          class="form-control"></textarea>
            <span class="help-block m-b-none">{{{_ "mongodb_version_warning" version="3.2"}}}</span>
        </div>
    </div>
</template>